import Vue from 'vue'

Vue.filter('yyyy-MM-dd', function(value) {
    if(value == null) return "";
    if(value.constructor === Date) {
        return [value.getFullYear()
                , value.getMonth() + 1
                , value.getDate()
                ].join("-");
    }
    return value;
});